package com.southwind.common;

import com.southwind.entity.Admin;
import com.southwind.entity.User;
import com.southwind.entity.Worker;
import lombok.AllArgsConstructor;
import lombok.Data;

@Data
@AllArgsConstructor
public class ResultObj {

    public static final ResultObj LOGIN_SUCCESS = new ResultObj(0, "登录成功");
    public static final ResultObj LOGIN_ERROR_LOGINNAME = new ResultObj(-1, "用户名或类型错误");
    public static final ResultObj LOGIN_ERROR_PASSWORD = new ResultObj(-1, "密码错误");
    public static final ResultObj LOGIN_ERROR_CODE = new ResultObj(-1, "验证码错误");

    public static final ResultObj MESSAGE_ADD_SUCCESS = new ResultObj(0, "留言添加成功");
    public static final ResultObj MESSAGE_ADD_ERROR = new ResultObj(-1, "留言添加失败");

    public static final ResultObj REPLY_ADD_SUCCESS = new ResultObj(0, "留言回复成功");
    public static final ResultObj REPLY_ADD_ERROR = new ResultObj(-1, "留言回复失败");

    public static final ResultObj AFTERSALES_ADD_SUCCESS = new ResultObj(0, "车辆售后添加成功");
    public static final ResultObj AFTERSALES_ADD_ERROR = new ResultObj(-1, "车辆售后添加失败");

    public static final ResultObj AFTERSALES_UPDATE_SUCCESS = new ResultObj(0, "车辆售后修改成功");
    public static final ResultObj AFTERSALES_UPDATE_ERROR = new ResultObj(-1, "车辆售后修改失败");

    public static final ResultObj USER_ADD_SUCCESS = new ResultObj(0, "用户信息添加成功");
    public static final ResultObj USER_ADD_ERROR = new ResultObj(-1, "用户信息添加失败");

    public static final ResultObj USER_UPDATE_SUCCESS = new ResultObj(0, "用户信息修改成功");
    public static final ResultObj USER_UPDATE_ERROR = new ResultObj(-1, "用户信息修改失败");

    public static final ResultObj USER_DELETE_SUCCESS = new ResultObj(0, "用户信息删除成功");
    public static final ResultObj USER_DELETE_ERROR = new ResultObj(-1, "用户信息删除失败");


    public static final ResultObj CAR_ADD_SUCCESS = new ResultObj(0, "车辆信息添加成功");
    public static final ResultObj CAR_ADD_ERROR = new ResultObj(-1, "车辆信息添加失败");

    public static final ResultObj CAR_UPDATE_SUCCESS = new ResultObj(0, "车辆信息修改成功");
    public static final ResultObj CAR_UPDATE_ERROR = new ResultObj(-1, "车辆信息修改失败");

    public static final ResultObj CAR_DELETE_SUCCESS = new ResultObj(0, "车辆信息删除成功");
    public static final ResultObj CAR_DELETE_ERROR = new ResultObj(-1, "车辆信息删除失败");


    public static final ResultObj WORKER_ADD_SUCCESS = new ResultObj(0, "工人添加成功");
    public static final ResultObj WORKER_ADD_ERROR = new ResultObj(-1, "工人添加失败");

    public static final ResultObj WORKER_UPDATE_SUCCESS = new ResultObj(0, "工人修改成功");
    public static final ResultObj WORKER_UPDATE_ERROR = new ResultObj(-1, "工人修改失败");

    public static final ResultObj WORKER_DELETE_SUCCESS = new ResultObj(0, "工人删除成功");
    public static final ResultObj WORKER_DELETE_ERROR = new ResultObj(-1, "工人删除失败");


    public static final ResultObj WORK_ADD_SUCCESS = new ResultObj(0, "工单派遣成功");
    public static final ResultObj WORK_ADD_ERROR = new ResultObj(-1, "工单派遣失败");

    public static final ResultObj WORK_FINISH_SUCCESS = new ResultObj(0, "工单已完成");
    public static final ResultObj WORK_FINISH_ERROR = new ResultObj(-1, "工单未完成");


    public static final ResultObj STATION_ADD_SUCCESS = new ResultObj(0, "工位添加成功");
    public static final ResultObj STATION_ADD_ERROR = new ResultObj(-1, "工位添加失败");

    public static final ResultObj STATION_UPDATE_SUCCESS = new ResultObj(0, "工位修改成功");
    public static final ResultObj STATION_UPDATE_ERROR = new ResultObj(-1, "工位修改失败");

    public static final ResultObj STATION_DELETE_SUCCESS = new ResultObj(0, "工位删除成功");
    public static final ResultObj STATION_DELETE_ERROR = new ResultObj(-1, "工位删除失败");


    public static final ResultObj SALES_ADD_SUCCESS = new ResultObj(0, "促销添加成功");
    public static final ResultObj SALES_ADD_ERROR = new ResultObj(-1, "促销添加失败");

    public static final ResultObj SALES_UPDATE_SUCCESS = new ResultObj(0, "促销修改成功");
    public static final ResultObj SALES_UPDATE_ERROR = new ResultObj(-1, "促销修改失败");

    public static final ResultObj SALES_DELETE_SUCCESS = new ResultObj(0, "促销删除成功");
    public static final ResultObj SALES_DELETE_ERROR = new ResultObj(-1, "促销删除失败");

    public ResultObj(Integer code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    private Integer code;
    private String msg;
    private Integer type;
    private Object user;
}
